import type { ProfileDetail } from "@/types/member"
import { sendRequest } from "@/utils/http"

//保存个人信息
export const saveProfileAPI = (profileParams: ProfileDetail) => {
    return sendRequest<string>({
      url: '/server-user/profile/saveProfile',
      method: 'PUT',
      data: profileParams
    })
  }

  //获取个人信息
  export const getProfileAPI = (userId:number) => {
    return sendRequest<ProfileDetail>({
      url: '/server-user/profile/getProfile',
      method: 'GET',
      data: {userId:userId}
    })
  }